<?php
require_once ('./lib/smarty/Smarty.class.php');

class Phones extends Smarty {
	public $minDate = 0;
	public $maxDate = 0;
	function Phones() {	
        $this->Smarty();
        
		require_once 'connect.php';
	    $mysql = connect();
	    $result = $mysql->query("SELECT MIN(`MMDDTT`) AS MIN_DATE, MAX(`MMDDTT`) AS MAX_DATE FROM `CallLog`")
	    		or die("Can't connect to MySQL DB");
		$row = $result->fetch_assoc();

		$this->minDate = date("Y-m-d",strtotime($row['MIN_DATE']));
		$this->maxDate = date("Y-m-d",strtotime($row['MAX_DATE']));
		
		$this->template_dir = './smarty_folders/templates/';
        $this->compile_dir = './smarty_folders/templates_c/';
        $this->config_dir = './smarty_folders/configs/';
        $this->cache_dir = './smarty_folders/cache/';
        
        //		$this->assign('path_to_css', './css/style.css');
        //		$this->assign('path_to_js', './js/');
        //		$this->assign('title', '');
        //		$this->assign('description', '');
        //		$this->assign('keywords', '');
        
        //$this->debugging = true;
        $this->caching = false;
		
    }
}
?>
